package com.autonavi.yunda.yunji.controller;

import com.autonavi.yunda.yunji.core.model.condition.OperationQueryCondition;
import com.autonavi.yunda.yunji.core.vo.response.OperationPageVO;
import com.autonavi.yunda.yunji.service.OperationRecordService;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.annotation.Resource;

/**
 * @author sunzhenbang
 */
@RestController
@RequestMapping("/operation")
public class OperationController {

    @Resource
    private OperationRecordService operationRecordService;

    @PostMapping("list")
    public OperationPageVO list(@Validated @RequestBody OperationQueryCondition request) {
        return operationRecordService.listPage(request);
    }

}
